package com.example.demo.service.orderService;

import com.example.demo.dao.OrderMapper;
import com.example.demo.pojo.Order;
import com.example.demo.service.furnService.FurnService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
@Service
public class OrderServiceImpl implements OrderService{
    @Resource
    OrderMapper orderMapper;
    @Resource
    FurnService furnService;

    @Override
    public boolean saveOrder(Order order) {
        orderMapper.insertSelective(order);
        return true;
    }

    @Override
    public boolean UpdateSalesAndStock(Integer id, Integer count) {
        furnService.UpdateSalesAndStock(id,count);
        return true;
    }

}
